import request from "@/utils/request";

// 查询平台列表
export function listPlatforms(params) {
  return request({
    url: "/mes/md/platform/list",
    method: "get",
    params,
  });
}

// 新增平台
export function addPlatform(data) {
  return request({
    url: "/mes/md/platform",
    method: "post",
    data,
  });
}

// 查询平台详情
export function getPlatform(id) {
  return request({
    url: `/mes/md/platform/${id}`,
    method: "get",
  });
}

// 编辑平台
export function editPlatform(data) {
  return request({
    url: `/mes/md/platform`,
    method: "put",
    data,
  });
}
